﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

using TJDevHouse.Starcraft.Game.RaceTypes;

namespace TJDevHouse.Starcraft.Game
{
	public class Races
	{
		private static Race _protoss = new Protoss();
		private static Race _terran = new Terran();
		private static Race _zerg = new Zerg();
		private static Race _neutral = new Neutral();
		private static Race _virtual = new Virtual(); //for gandalf and co.

		public static Race Protoss
		{
			get
			{
				return _protoss;
			}
		}
		public static Race Terran
		{
			get
			{
				return _terran;
			}
		}
		public static Race Zerg
		{
			get
			{

				return _zerg;
			}
		}
		public static Race Neutral
		{
			get
			{
				return _neutral;
			}
		}

		public static Race Virtual
		{
			get
			{
				return _virtual;
			}
		}

		/// <summary>
		/// Get a race by its BWAPI ID.
		/// </summary>
		/// <param name="ID"></param>
		/// <returns></returns>
		public static Race GetRaceByBWAPIRaceID(int ID)
		{
			switch (ID)
			{
				case 0:
					return Zerg;
				case 1:
					return Terran;
				case 2:
					return Protoss;
				default:
					return Neutral;
			}
		}
	}
}
